#ifndef _DAEMONERROR_H_
#define _DAEMONERROR_H_

#include <exception>

#include <string>

using std::exception;
using std::string;

namespace Tubox {

class DaemonError : public exception {
public:
	DaemonError(const string& error, const unsigned int status = 999) : error(error), status(status) { }
	virtual const char* what() const throw() {
		return error.c_str();
	}
	unsigned int getStatus() const { return status; }
	~DaemonError() throw() { }
private:
	string error;
	unsigned int status;
};

}

#endif
